home *** CD-ROM | disk | FTP | other *** search
Modula Definition | 1994-12-23 | 600 b | 20 lines |
- DEFINITION MODULE CliArgs ;
-
- (* If your prgram will only run under 2.0+ amigas then you may like to use *)
- (* Dos.ReadArgs instead. *)
-
- VAR
- truncated : BOOLEAN ;
-
- PROCEDURE GetArgCount( ) : LONGINT ;
- (* Returns the number of arguments specified on the command line *)
- (* eg 'm2c x.mod' would return 2 *)
-
- PROCEDURE GetArg( n : LONGINT ; VAR arg : ARRAY OF CHAR ) ;
- (* If n > GetArgCount-1 then the program aborts execution *)
- (* Arg 0 = program name. *)
- (* If the argument does not fit in the array then it is truncated *)
- (* and truncated := TRUE *)
-
- END CliArgs.
-